<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ include file="/common/taglibs.jsp"%>
<%@ page import="com.msmall.base.util.ConstantDB" language="java"%>
<c:set var="KEYWORD_TYPE_SITE_INDEX_WIKI_BABY" value="<%=ConstantDB.KEYWORD_TYPE_SITE_INDEX_WIKI_BABY%>"></c:set>
<c:set var="KEYWORD_TYPE_COOKBOOK_BABY" value="<%=ConstantDB.KEYWORD_TYPE_COOKBOOK_BABY%>"></c:set>

<div class="ind_module happybaby">
	<div class="happybabyleft">
		<p class="happybabynav"></p>
		<p class="martop10">
			<a href="<c:url value='/klg/article/viewArticle.do?articleid=${babyIndexBabyImage.entityId}'/>" target="_blank">
				<img src ="${ctx}/${babyIndexBabyImage.htmlImage}" style="width:300px;height:180px;" alt="${babyIndexBabyImage.imageAlt}" />
			</a>
		</p>
		<p class="luckmothleftp martop10">宝宝话题</p>
		<ul class="hbabyleftul">
			<c:forEach var="commend" items="${babyKlgHot}">
				<li>
					<a class="l666" href="<c:url value='/klg/article/viewArticle.do?articleid=${commend.obj.articleid}'/>" target="_blank">
					<c:out value="${commend.obj.title}"/>
					</a>
				</li>
			</c:forEach>
		</ul>
	</div>
	<div id="babyIndexBabyTabs" class="w460 fl">
		<div id="babyIndexBabyTabsHeader" class="hbabycentnav">
	    	<c:forEach var="cascadeC" items="${babyTopSegment}" varStatus="segmentStatus">
	    		<c:set var="segment" value="${cascadeC.current}"></c:set>
		    	<p id="babyIndexBabyTabs-${segment.segmentid}" class="">
	    			<c:out value='${segment.title}'/>
	    		</p>
	    	</c:forEach>
		</div>
	    	<c:forEach var="cascadeC" items="${babyTopSegment}" varStatus="segmentStatus">
	    		<c:set var="segment" value="${cascadeC.current}"></c:set>
	    		<c:set var="eachImages" value="${babyKlgEachImages[segment.segmentid]}"></c:set>
	    		<c:set var="eachTopNews" value="${babyKlgEachTopNews[segment.segmentid]}"></c:set>
	    		<c:set var="eachHot" value="${babyKlgEachHot[segment.segmentid]}"></c:set>
			    	<div id="babyIndexBabyTabs-content-${segment.segmentid}" class="hbabycentnavbgContent" style="display:none">
			    		<c:forEach var="commendImage" items="${eachImages}" varStatus="status1">
			    			<c:if test="${status1.count == 1}">
			    				<dl class="hbabycentdl">
			    					<dt>
			    						<span></span>
				    					<a href="<c:url value='/klg/article/viewArticle.do?articleid=${commendImage.entityId}'/>" target="_blank">
											<c:out value="${commendImage.imageAlt}"></c:out>
										</a>
										<img style="width:100px;height:130px;" src ="${ctx}/${commendImage.htmlImage}" alt="${commendImage.imageAlt}" />
									</dt>
									<dd>
										<c:forEach var="hotArticle" items="${eachHot}" varStatus="hotStatus">
											<c:if test="${hotStatus.count <=5}">
												<p>
													<a class="lH33" href="<c:url value='/klg/article/viewArticle.do?articleid=${hotArticle.articleid}'/>" target="_blank">
														<c:out value="${hotArticle.title}"/>
													</a>
												</p>
											</c:if>
										</c:forEach>
									</dd>
			    				</dl>
			    			</c:if>
			    			<c:if test="${status1.count == 2}">
			    				<dl class="hbabycentdl1">
			    					<c:forEach var="topNewsArticle" items="${eachTopNews}" varStatus="hotStatus">
										<c:if test="${hotStatus.count == 1}">
											<dt>
												<a class="lB705" href="<c:url value='/klg/article/viewArticle.do?articleid=${topNewsArticle.obj.articleid}'/>" target="_blank">
													<c:out value="${topNewsArticle.obj.title}"/>
												</a>
											</dt>
											<dd>
												<c:out value="${topNewsArticle.obj.contentAbstract}"/>
											</dd>
										</c:if>
									</c:forEach>
			    				</dl>
			    				<dl class="hbabycentdl">
			    					<dt>
			    						<span></span>
				    					<a href="<c:url value='/klg/article/viewArticle.do?articleid=${commendImage.entityId}'/>" target="_blank">
											<c:out value="${commendImage.imageAlt}"/>
										</a>
										<img src ="${ctx}/${commendImage.htmlImage}" width="100px" height="130px" alt="${commendImage.imageAlt}" />
									</dt>
									<dd>
										<c:forEach var="hotArticle" items="${eachHot}" varStatus="hotStatus">
											<c:if test="${hotStatus.count >=6 && hotStatus.count <=10}">
												<p>
													<a class="lH33" href="<c:url value='/klg/article/viewArticle.do?articleid=${hotArticle.articleid}'/>" target="_blank">
														<c:out value="${hotArticle.title}"/>
													</a>
												</p>
											</c:if>
										</c:forEach>
									</dd>
			    				</dl>
			    			</c:if>
			    		</c:forEach>
			    	</div>
	    	</c:forEach>
	</div>
	<div class="happybabyrigh fr">
		<p class="hbabyrighnav1">
			宝宝的字典
		</p>
		<div class="hbabyrighdiv">
			<tiles:insertDefinition name="html.wiki.babyjoinmother.preparer">
				<tiles:putAttribute name="keywordType" value="${KEYWORD_TYPE_SITE_INDEX_WIKI_BABY}"></tiles:putAttribute>
			</tiles:insertDefinition>
		</div>
		<p class="hbabyrighnav2 martop10">宝宝的食谱</p>
		<div class=hbabyrighdiv>
			<tiles:insertDefinition name="html.keyword.cookbook.preparer">
				<tiles:putAttribute name="keywordType" value="${KEYWORD_TYPE_COOKBOOK_BABY}"></tiles:putAttribute>
			</tiles:insertDefinition>
		</div>
	</div>
</div>
<script>
$.each($("#babyIndexBabyTabsHeader p"),function(i, n){
	n.onmouseover=function(){
		this.timer=window.setTimeout(function(){
		$("#babyIndexBabyTabsHeader p").removeClass("hbabycentnavbg").addClass("");
		$("#babyIndexBabyTabs .hbabycentnavbgContent").css("display","none").eq(i).css("display","block");
		n.className="hbabycentnavbg";
		},100)
	};
	n.onmouseout=function(){window.clearTimeout(this.timer);}
});
$("#babyIndexBabyTabsHeader p:first").mouseover(); 
</script>